﻿using SimpleWifi;

namespace JMBox.Utils
{
    public class RandomNumTool
    {
        private static readonly Random random = new Random();

        public static int[] GenerateRandomNumbers(int a, int b, int n)
        {
            int[] randomNumbers = new int[n];
            for (int i = 0; i < n; i++)
            {
                // Random.Next(int minValue, int maxValue) generates a number >= minValue and < maxValue
                // Therefore, we add 1 to include 'b' in the range
                randomNumbers[i] = random.Next(a, b + 1);
            }

            return randomNumbers;
        }
            
    }
}
